package test2

import "fmt"

type MyInterface interface {
	M1()
}

type T int
func (T) M1() {
	println("T's M1")

}

func Test1() {
	var t T
	var i interface{} = t
	v1, ok := i.(MyInterface)
	if !ok {
		panic("值不是 MyInterface接口类型")
	}
	v1.M1()
	i = int64(13)
	v2, ok := i.(MyInterface)
	fmt.Println(v2, ok)
}
